Techniques for suggesting electronic messages based on user activity and other context

ABSTRACT

A computer-implemented technique can include detecting an initiation of composing an electronic message by a user, obtaining contextual information for the electronic message from a source external to a text of the electronic message, obtaining a first suggestion for the text of the electronic message based on the contextual information, detecting an operating condition indicative of a user activity during which the user is likely to experience difficulty in typing, in response to detecting the operating condition, obtaining a second suggestion for the electronic message based on the contextual information, the second suggestion being more detailed than the first suggestion, and outputting one of the first and second suggestions depending on one or more other conditions.

BACKGROUND

The background description provided herein is for the purpose ofgenerally presenting the context of the disclosure. Work of thepresently named inventors, to the extent it is described in thisbackground section, as well as aspects of the description that may nototherwise qualify as prior art at the time of filing, are neitherexpressly nor impliedly admitted as prior art against the presentdisclosure.

Electronic messaging, such as text messaging and emailing, has becomeone of the primary methods by which people communicate. There are times,however, when it can be difficult for a user to type an electronicmessage using a keyboard. Conventional systems can suggest one or moreof a few pre-generated messages, such as in response to a shorthandinput (“brt” can result in the suggestion “be right there,” “omw” canresult in the suggestion “on my way,” etc.). These pre-generatedmessages, however, are generic and lack any specific context, such as acontext of the user's current activity.

SUMMARY

According to one aspect of the present disclosure, acomputer-implemented method is presented. The method can includedetecting, by a computing device having one or more processors, aninitiation of composing an electronic message by a user; obtaining, bythe computing device, contextual information for the electronic messagefrom a source external to a text of the electronic message; obtaining,by the computing device, a first suggestion for the text of theelectronic message based on the contextual information; detecting, bythe computing device, an operating condition indicative of a useractivity during which the user is likely to experience difficulty intyping; in response to detecting the operating condition, obtaining, bythe computing device, a second suggestion for the electronic messagebased on the contextual information, the second suggestion being moredetailed than the first suggestion; and outputting, by the computingdevice, one of the first and second suggestions depending on one or moreother conditions.

In some implementations, the detecting of the operating condition isbased on a measured gravitational force. In some implementations, theuser activity is walking or running, and the measured gravitationalforce indicates that the user is walking or running. In someimplementations, the user activity is waiting in a line, and themeasured gravitational force indicates that the user is waiting in aline.

In some implementations, the one or more other conditions include theuser arriving at a known location, the outputting includes outputtingthe second suggestion, and the second suggestion relates to the arrivalat the known location. In some implementations, (i) the first suggestionis a word and the second suggestion is a phrase or a sentence or (ii)the first suggestion is the word or the phrase and the second suggestionis the sentence.

In some implementations, the contextual information includes previouselectronic messages associated with the user. In some implementations,the contextual information includes a date/time stamp for a particularprevious electronic message comprising a question to the user.

In some implementations, the contextual information includes calendarinformation for the user. In some implementations, the calendarinformation includes at least one of (i) a type of an activity the useris currently engaged in and (ii) at least one of a start time and an endtime of the activity that the user is currently engaged in.

In some implementations, the computing device is a client computingdevice associated with the user. In some implementations, the computingdevice is a server computing device that is distinct from a clientcomputing device associated with the user.

According to another aspect of the present disclosure, a computingdevice is presented. The computing device can include a non-transitorycomputer-readable medium having a set of instructions stored thereon andone or more processors configured to execute the set of instructions,which causes the one or more processors to perform operations. Theoperations can include detecting an initiation of composing anelectronic message by a user; obtaining contextual information for theelectronic message from a source external to a text of the electronicmessage; obtaining a first suggestion for the text of the electronicmessage based on the contextual information; detecting an operatingcondition indicative of a user activity during which the user is likelyto experience difficulty in typing; in response to detecting theoperating condition, obtaining a second suggestion for the electronicmessage based on the contextual information, the second suggestion beingmore detailed than the first suggestion; and outputting one of the firstand second suggestions depending on one or more other conditions.

In some implementations, the detecting of the operating condition isbased on a measured gravitational force. In some implementations, theuser activity is walking or running, and the measured gravitationalforce indicates that the user is walking or running. In someimplementations, the user activity is waiting in a line, and themeasured gravitational force indicates that the user is waiting in aline.

In some implementations, the one or more other conditions include theuser arriving at a known location, the outputting includes outputtingthe second suggestion, and the second suggestion relates to the arrivalat the known location. In some implementations, (i) the first suggestionis a word and the second suggestion is a phrase or a sentence or (ii)the first suggestion is the word or the phrase and the second suggestionis the sentence.

In some implementations, the contextual information includes previouselectronic messages associated with the user. In some implementations,the contextual information includes a date/time stamp for a particularprevious electronic message comprising a question to the user.

In some implementations, the contextual information includes calendarinformation for the user. In some implementations, the calendarinformation includes at least one of (i) a type of an activity the useris currently engaged in and (ii) at least one of a start time and an endtime of the activity that the user is currently engaged in.

In some implementations, the second suggestion is obtained in responseto the user inputting a prefix of the electronic message. In someimplementations, the computing device is a client computing deviceassociated with the user. In some implementations, the computing deviceis a server computing device that is distinct from a client computingdevice associated with the user.

Further areas of applicability of the present disclosure will becomeapparent from the detailed description provided hereinafter. It shouldbe understood that the detailed description and specific examples areintended for purposes of illustration only and are not intended to limitthe scope of the disclosure.

BRIEF DESCRIPTION OF THE DRAWINGS

The present disclosure will become more fully understood from thedetailed description and the accompanying drawings, wherein:

FIG. 1 is a diagram of an example computing system according to someimplementations of the present disclosure;

FIG. 2 is a functional block diagram of an example computing deviceaccording to some implementations of the present disclosure;

FIG. 3 is a flow diagram of an example method for suggesting electronicmessages based on user activity and other context according to someimplementations of the present disclosure; and

FIGS. 4A-4C are example user interfaces according to someimplementations of the present disclosure.

DETAILED DESCRIPTION

As mentioned above, typical pre-generated suggestions for electronicmessaging lack any specific context, such as a context of a user'scurrent activity. Some systems may derive a context of the electronicmessage from one or more previous words, but this still fails to captureany context outside of those one or more words. Such systems also do notwork when the user has yet to input any words. Accordingly, improvedtechniques for suggesting electronic messages based on user activity andother context are presented. These techniques can leverage other sourcesof information to determine context for the electronic message andthereby provide more detailed suggestions. Such sources of informationcan be referred to as “external sources” that indicate any context of aparticular electronic message that is not derived from its text.

Non-limiting examples of these external sources include user calendarinformation, other electronic messages, past and/or present userlocation information, and accelerometer information. In someimplementations, an operating condition can be detected that isindicative of a user activity during which the user is likely toexperience difficulty typing at their client computing device. Thisoperating condition could be detected, for example, when a gravitationalforce (“g-force”) being experienced by the client computing deviceexceeds a threshold (e.g., indicative of the user walking or running).When such an operating condition is detected, a more detailed suggestioncould be provided based on the obtained contextual information. Insteadof suggesting just a few words, such as “On my way,” a full sentencecould be suggested, such as “I'm jogging down Main Street and should bethere in 10 minutes.”

The techniques of the present disclosure could be at least partiallyimplemented by an electronic messaging application executing at a clientcomputing device. This electronic messaging application could be, forexample only, a standalone electronic messaging application.Non-limiting example user interfaces are discussed herein andillustrated in FIGS. 4A-4C. Additionally or alternatively, thesetechniques could be at least partially implemented at an operatingsystem level at the client computing device. Further, at least a portionof these techniques could be implemented at a server computing device.The server computing device could, for example, provide a response to arequest from the client computing device.

The present disclosure is directed to, inter alia, the technical problemof interpreting and classifying user input in a messaging application.More specifically, the present disclosure is directed to techniques forproviding appropriate suggested messages in a messaging applicationbased on the external context of the user and her/his associated clientcomputing device. The techniques utilize various hardware components andother forms of previously input information to analyze the externalcontext of the messaging application. Based on the external context, andwhen the user initiates the composition of a message, the techniquesprovide for determining and outputting one or more fully formed outputsuggestions that are appropriate for the external context of the message(e.g., the context of the message independent of its previously inputtext).

Referring now to FIG. 1, an example computing system 100 according tosome implementations of the present disclosure is illustrated. Thecomputing system 100 can include a client computing device 104 that cancommunicate with a remote server computing device 108 via a network 112.The network 112 can be a local area network (LAN), a wide area network(WAN), e.g., the Internet, or a combination thereof. While the clientcomputing device 104 is shown to be a mobile phone, it will beappreciated that the client computing device 104 can be any suitablemobile computing device (a tablet computer, a laptop computer, etc.).The server computing device 108 can be any suitable hardware server orplurality of hardware servers operating in a parallel or distributedarchitecture. A first user 116 can operate the client computing device104, such as to exchange electronic messages (text messages, emails,etc.) via the network 112 with another computing device 120 associatedwith a second user 124.

Referring now to FIG. 2, an example computing device 200 is illustrated.The client computing device 104, the server computing device 108, andthe other computing device 120 can each have the same or similarconfiguration as the example computing device 200. The computing device200 can include a communication device 204 (e.g., a transceiver)configured for communication via the network 112. The computing device200 can include a user interface 208 (e.g., a touch display) configuredto receive input and/or output information from/to a user 220 (e.g.,user 116 or user 124). The computing device 200 can include anon-transitory computer-readable medium or memory 212 (flash, hard disk,etc.) configured to store information at the computing device 200. Thecomputing device 200 can also include a processor 216 configured tocontrol operation of the computing device 200.

The term “processor” as used herein can refer to both a single processorand a plurality of processors operating in a parallel or distributedarchitecture. In one implementation, the memory 212 may store a set ofinstructions that, when executed by the processor 216, causes thecomputing device 200 to perform at least a portion of the techniques ofthe present disclosure. The computing device 200 can also include othersystems, such as an accelerometer 220 and a global positioning satellite(GPS) receiver 224. The accelerometer 220 can be any suitableaccelerometer or system of accelerometers configured to measure agravitational force (“g-force”) experienced by the computing device 200.The GPS receiver 224 can communicate with a GPS system (not shown) toobtain global position data (e.g., location information) for thecomputing device 200. The use of the accelerometer 220 and GPS receiver224 will be discussed in more detail below.

According to one aspect of the present disclosure, the computing system100 can determine suggestion(s) for a text of an electronic messagebeing composed by the first user 116 of the client computing device 104.These techniques can be initiated, for example, upon the initiation ofcomposing the electronic message (e.g., selecting or clicking a textentry box or an input field of a messaging application). After thecomposing of the electronic message is initiated, the computing system100 can determine context information from a source external to the textof the electronic message. This “external context” refers to anyinformation other than the actual text of the electronic message (e.g.,previous characters or words). One example of this external contextinformation is previous messages associated with the first user 116. Forexample, if the first user 116 is addressing the electronic message tothe second user 124, previous electronic messages between the two couldbe analyzed to determine the external context information.

In one implementation, the computing system 100 can obtain aconversation topic from the previous electronic messages. For example,the conversation topic could be meeting for dinner. The computing system100 can identify dates/times across the whole conversation and resolvethe dates and times relative to the time the message was sent. Thecomputing system 100 can also identify open or unanswered questions fromthe previous electronic messages. For example, one of the more recentelectronic messages could be “when are you coming?” or “when will youarrive?” The question can be identified as open if a response has notyet been provided. An estimated time of arrival for the first user 116could be estimated using external context information, such as the typeof activity and/or location information, and then utilized in respondingto such a question, e.g., “on the bus, be there in 15 minutes.” Thesuggestions could also be generated and/or filtered as the first user116 enters text. For example, if the first user 116 types “I'm” inconnection with a previous message “when will you arrive,” then thesuggestion could be “I'm on my way.”

As mentioned above, the accelerometer 220 can be configured to measure ag-force being experienced by the client computing device 104. Thisinformation can then be used to detect a certain type of motion. Onceexample type of motion is the first user 116 is walking or running.While walking or running, the first user 116 may experience difficultyin typing at the client computing device 104 and thus the suggestionsmay be more detailed, e.g., a full sentence instead of a word or phrase.Other types of motion can be initiating or being in the process of aparticular type of transportation, such as getting into a car, boardingpublic transportation (e.g., a bus or train), getting onto a bicycle, orentering an elevator. For example, it may be difficult for a user totype when they need to hold an object, such as a pole while standing ona train or subway car. Location information and movement informationcaptured by the GPS receiver 224 can also be used to detect the type ofmotion. Other types of motion can include waiting in a line or queue,which can involve periodic slow movements separated by static ornon-moving periods, but it still may be difficult for the users to typea full message due to the repeated interruption and/or fear of causing abackup of others behind them in line.

As mentioned above, location information for the client computing device104 can be utilized to provide more detailed suggestions, such as inresponse to a change in user location. Known locations (e.g.,previously/frequently visited locations), such as a workplace or home ofthe first user 116, could be leveraged to provide a related message,such as “just got home” or “just got to work.” There could be even moredetailed location information, such as indoor location information orindoor positioning, and thus a suggestion could be as detailed as “justarrived at my desk.” Calendar information could be similarly leveragedto determine when the first user 116 has a scheduled event and, when theclient computing device 104 arrives at the corresponding location, thesuggested message could be “just arrived.” Suggestions could also beprovided based on the known current activity, which could again bedetermined from user history (previously/frequently visited locations),location information, and/or calendar/schedule information. For example,the location could be a grocery store, and the suggested message couldbe “just getting some groceries from the store.” Their current activitycould also be one where they would not want to continue communicating,such as while they are in a work meeting, which could be determined fromtheir calendar information (e.g., activity description, start time, andend time). In this type of scenario, a suggested message could be “I'llcontact you later.”

The exact suggested messages can also be specific to the first user 116.More specifically, a user-specific language model can be generated andtrained based on the activity by the first user 116 (e.g., by usingmachine learning techniques). These machine learning techniques canidentify or recognize patterns associated with the user, such as oftenused words and phrases. These patterns can be leveraged to create theuser-specific language model, which can then predict a most-likelymessage to suggest (e.g., a possible suggest message having a highestrespective probability score). The term language model as used hereincan refer to a probability distribution over a sequence of text(characters, word, phrases, etc.) that is derived from (or “trained”based on) training data. In some implementations, a language model canassign a probability to a piece of unknown text (character, word,phrase, etc.) based on external context information (previous messages,location information, etc.) and a corpus of training data upon which thelanguage model is trained. This training data, for example, can berelated to the first user 116.

By utilizing this user-specific language model, the suggestions shouldmimic the style/tone of the first user 116, which may make the suggestedelectronic messages more applicable for the first user 116 because thereceiving user (e.g., the second user 124) may be more likely to believethat the first user 116 actually typed the message as opposed to justselecting one of a few pre-generated messages. Cross-user machinelearning could also be performed, and a global or non-user-specificlanguage model could be generated and trained (e.g., based on userfeedback indicative of which suggestions are high quality suggestions).Learning could also be performed to associate certain types ofactivities with average statistics (e.g., grocery shopping takes anaverage user approximately 30 minutes), which could then be leveraged toprovide even better suggestions (e.g., “I'm at the grocery store. I'llbe done in 20 minutes!”). There can also be various sub-categories forcertain activities/statistics. For example only, grocery shopping maytake an average user approximately 20 minutes during the middle of awork day, such as at 11:00 am, whereas it may take an average userapproximately 40 minutes in the evening of the work day, such as at 6:00pm.

Referring now to FIG. 3, an example method 300 for suggesting electronicmessages based on user activity and other context is presented. At 304,the computing system 100 can detect whether composing an electronicmessage at the client computing device 104 has been initiated. Thiscould be, for example, in response to the user selecting or clicking atext entry area or an input field in an electronic messaging application(see input field 404 in FIGS. 4A-4C). If true, the method 300 canproceed to 308. At 308, the computing system 100 can obtain contextualinformation for the electronic message from a source external to a textof the electronic message. At 312, the computing system 100 (e.g., theserver computing device 108) can obtain a first suggestion for the textof the electronic message based on the external contextual information.

At 316, the computing system 100 can detect an operating conditionindicative of a user activity during which the first user 116 is likelyto experience difficulty in typing at the client computing device 104.When the operating condition is detected, the method 300 can proceed to320. Otherwise, the method 300 can proceed to 324. At 320, the computingsystem 100 can obtain a second suggestion for the electronic messagebased on the contextual information, the second suggestion being moredetailed than the first suggestion. At 324, the computing system 100 canoutput (e.g., from the server computing device 108 to the clientcomputing device 104) either the first or second suggestion, dependingon the decision at 316. The first user 116 could then utilize theprovided suggestion in composing the electronic message, which can thenbe sent to the other computing device 120 via the network 112.

Referring now to FIGS. 4A-4C, example user interfaces according to someimplementations of the present disclosure are illustrated. Specifically,three different user interfaces that are output via the user interface208 (e.g., a touch display) of the client computing device 104 areillustrated. The user interfaces each include a message area 400, aninput area 404, and a keyboard area 408. The keyboard displayed in thekeyboard area 408 could be a physical keyboard, a virtual keyboard, orsome combination thereof. As seen in FIG. 4A, a first suggestion 412 fora text of an electronic message (“On my way”) has been suggested. Thisfirst suggestion 412 could be generated based on an external context ofthe electronic message, and could be generated/output without the firstuser 116 having input any text for the electronic message. Examples ofthis external context are the previous messages that are displayed inmessage area 400. As shown, another user (e.g., second user 124) sentthe electronic message “Want to grab lunch? I'm at Joe's Diner.” Thiselectronic message was time stamped at 12:15 pm. In response, the firstuser 116 of the client computing device 104 sent the electronic message“Sure!” This electronic message was time stamped at 12:17 pm.

Some examples of the context that can be derived from these electronicmessages are the type of activity (eating), the location (“Joe's Diner”)and the confirmation (“Sure!”). These electronic messages are alsoproximate in time, as opposed to the first user 116 of the clientcomputing device 104 responding “Sure!” at 6:00 pm, which would not beappropriate for still meeting for lunch. As shown, the other user (e.g.,second user 124) has also sent another message at 12:19 pm (“Where areyou? ETA?”). This provides further context for the first suggestion “Onmy way.” That is, the other user has inquired where the first user 116of the client computing device 104 is and when they will arrive. Aspreviously discussed herein, the first suggestion 412 may be inadequatein certain scenarios. As shown in FIG. 4B, a g-force 420 (e.g.,vibration) of the client computing device 104 could be detected usingaccelerometer 220, which can indicate that the first user 116 of theclient computing device 104 is walking or running. In response todetecting such an operating condition or any of the other particularoperating conditions discussed herein, a more detailed second suggestionfor the text of the electronic message can be provided.

As shown in FIG. 4C, a more detailed second suggestion 416 has beenprovided. This second suggestion 416 is “Walking down Main Street. Bethere in 2 minutes!” This second suggestion 416 is more detailed thanthe first suggestion 412 (“On my way.”) in that it provides moreinformation and/or more appropriately answers the other user's previousquestion (“Where are you? ETA?”). This second suggestion could also begenerated based on the external context of the electronic message.Examples of this context include location information (e.g., GPS datafrom GPS receiver 224) for the client computing device 104, from whichit can be determined that the first user 116 is walking down aparticular street and is approximately two minutes from arriving at thedestination (“Joe's Diner”). While the second suggestion 416 is shown asreplacing the first suggestion 412, it will be appreciated that thefirst suggestion 412 may not be provided to the first user 116. In otherwords, the operating condition could be detected shortly after receivingthe most recent electronic message (“Where are you? ETA?”), and thesecond suggestion 416 could thereafter be provided.

One or more systems and methods discussed herein do not requirecollection or usage of user personal information. In situations in whichcertain implementations discussed herein may collect or use personalinformation about users (e.g., user data, information about a user'ssocial network, user's location and time, user's biometric information,user's activities and demographic information), users are provided withone or more opportunities to control whether the personal information iscollected, whether the personal information is stored, whether thepersonal information is used, and how the information is collected aboutthe user, stored and used. That is, the systems and methods discussedherein collect, store and/or use user personal information only uponreceiving explicit authorization from the relevant users to do so. Inaddition, certain data may be treated in one or more ways before it isstored or used so that personally identifiable information is removed.As one example, a user's identity may be treated so that no personallyidentifiable information can be determined. As another example, a user'sgeographic location may be generalized to a larger region so that theuser's particular location cannot be determined.

Example embodiments are provided so that this disclosure will bethorough, and will fully convey the scope to those who are skilled inthe art. Numerous specific details are set forth such as examples ofspecific components, devices, and methods, to provide a thoroughunderstanding of embodiments of the present disclosure. It will beapparent to those skilled in the art that specific details need not beemployed, that example embodiments may be embodied in many differentforms and that neither should be construed to limit the scope of thedisclosure. In some example embodiments, well-known procedures,well-known device structures, and well-known technologies are notdescribed in detail.

The terminology used herein is for the purpose of describing particularexample embodiments only and is not intended to be limiting. As usedherein, the singular forms “a,” “an,” and “the” may be intended toinclude the plural forms as well, unless the context clearly indicatesotherwise. The term “and/or” includes any and all combinations of one ormore of the associated listed items. The terms “comprises,”“comprising,” “including,” and “having,” are inclusive and thereforespecify the presence of stated features, integers, steps, operations,elements, and/or components, but do not preclude the presence oraddition of one or more other features, integers, steps, operations,elements, components, and/or groups thereof. The method steps,processes, and operations described herein are not to be construed asnecessarily requiring their performance in the particular orderdiscussed or illustrated, unless specifically identified as an order ofperformance. It is also to be understood that additional or alternativesteps may be employed.

Although the terms first, second, third, etc. may be used herein todescribe various elements, components, regions, layers and/or sections,these elements, components, regions, layers and/or sections should notbe limited by these terms. These terms may be only used to distinguishone element, component, region, layer or section from another region,layer or section. Terms such as “first,” “second,” and other numericalterms when used herein do not imply a sequence or order unless clearlyindicated by the context. Thus, a first element, component, region,layer or section discussed below could be termed a second element,component, region, layer or section without departing from the teachingsof the example embodiments.

As used herein, the term module may refer to, be part of, or include: anApplication Specific Integrated Circuit (ASIC); an electronic circuit; acombinational logic circuit; a field programmable gate array (FPGA); aprocessor or a distributed network of processors (shared, dedicated, orgrouped) and storage in networked clusters or datacenters that executescode or a process; other suitable components that provide the describedfunctionality; or a combination of some or all of the above, such as ina system-on-chip. The term module may also include memory (shared,dedicated, or grouped) that stores code executed by the one or moreprocessors.

The term code, as used above, may include software, firmware, byte-codeand/or microcode, and may refer to programs, routines, functions,classes, and/or objects. The term shared, as used above, means that someor all code from multiple modules may be executed using a single(shared) processor. In addition, some or all code from multiple modulesmay be stored by a single (shared) memory. The term group, as usedabove, means that some or all code from a single module may be executedusing a group of processors. In addition, some or all code from a singlemodule may be stored using a group of memories.

The techniques described herein may be implemented by one or morecomputer programs executed by one or more processors. The computerprograms include processor-executable instructions that are stored on anon-transitory tangible computer readable medium. The computer programsmay also include stored data. Non-limiting examples of thenon-transitory tangible computer readable medium are nonvolatile memory,magnetic storage, and optical storage.

Some portions of the above description present the techniques describedherein in terms of algorithms and symbolic representations of operationson information. These algorithmic descriptions and representations arethe means used by those skilled in the data processing arts to mosteffectively convey the substance of their work to others skilled in theart. These operations, while described functionally or logically, areunderstood to be implemented by computer programs. Furthermore, it hasalso proven convenient at times to refer to these arrangements ofoperations as modules or by functional names, without loss ofgenerality.

Unless specifically stated otherwise as apparent from the abovediscussion, it is appreciated that throughout the description,discussions utilizing terms such as “processing” or “computing” or“calculating” or “determining” or “displaying” or the like, refer to theaction and processes of a computer system, or similar electroniccomputing device, that manipulates and transforms data represented asphysical (electronic) quantities within the computer system memories orregisters or other such information storage, transmission or displaydevices.

Certain aspects of the described techniques include process steps andinstructions described herein in the form of an algorithm. It should benoted that the described process steps and instructions could beembodied in software, firmware or hardware, and when embodied insoftware, could be downloaded to reside on and be operated fromdifferent platforms used by real time network operating systems.

The present disclosure also relates to an apparatus for performing theoperations herein. This apparatus may be specially constructed for therequired purposes, or it may comprise a general-purpose computerselectively activated or reconfigured by a computer program stored on acomputer readable medium that can be accessed by the computer. Such acomputer program may be stored in a tangible computer readable storagemedium, such as, but is not limited to, any type of disk includingfloppy disks, optical disks, CD-ROMs, magnetic-optical disks, read-onlymemories (ROMs), random access memories (RAMs), EPROMs, EEPROMs,magnetic or optical cards, application specific integrated circuits(ASICs), or any type of media suitable for storing electronicinstructions, and each coupled to a computer system bus. Furthermore,the computers referred to in the specification may include a singleprocessor or may be architectures employing multiple processor designsfor increased computing capability.

The algorithms and operations presented herein are not inherentlyrelated to any particular computer or other apparatus. Variousgeneral-purpose systems may also be used with programs in accordancewith the teachings herein, or it may prove convenient to construct morespecialized apparatuses to perform the required method steps. Therequired structure for a variety of these systems will be apparent tothose of skill in the art, along with equivalent variations. Inaddition, the present disclosure is not described with reference to anyparticular programming language. It is appreciated that a variety ofprogramming languages may be used to implement the teachings of thepresent disclosure as described herein, and any references to specificlanguages are provided for disclosure of enablement and best mode of thepresent invention.

The present disclosure is well suited to a wide variety of computernetwork systems over numerous topologies. Within this field, theconfiguration and management of large networks comprise storage devicesand computers that are communicatively coupled to dissimilar computersand storage devices over a network, such as the Internet.

The foregoing description of the embodiments has been provided forpurposes of illustration and description. It is not intended to beexhaustive or to limit the disclosure. Individual elements or featuresof a particular embodiment are generally not limited to that particularembodiment, but, where applicable, are interchangeable and can be usedin a selected embodiment, even if not specifically shown or described.The same may also be varied in many ways. Such variations are not to beregarded as a departure from the disclosure, and all such modificationsare intended to be included within the scope of the disclosure.

What is claimed is:
 1. A computer-implemented method, comprising:detecting, by a computing device having one or more processors, aninitiation of composing an electronic message by a user; obtaining, bythe computing device, contextual information for the electronic messagefrom a source external to a text of the electronic message; obtaining,by the computing device, a first suggestion for the text of theelectronic message based on the contextual information; detecting, bythe computing device, an operating condition indicative of a useractivity during which the user is likely to experience difficulty intyping; in response to detecting the operating condition, obtaining, bythe computing device, a second suggestion for the electronic messagebased on the contextual information, the second suggestion being moredetailed than the first suggestion; and outputting, by the computingdevice, one of the first and second suggestions depending on one or moreother conditions.
 2. The computer-implemented method of claim 1, whereinthe detecting of the operating condition is based on a measuredgravitational force.
 3. The computer-implemented method of claim 2,wherein the user activity is walking or running, and wherein themeasured gravitational force indicates that the user is walking orrunning.
 4. The computer-implemented method of claim 2, wherein the useractivity is waiting in a line, and wherein the measured gravitationalforce indicates that the user is waiting in a line.
 5. Thecomputer-implemented method of claim 1, wherein the one or more otherconditions include the user arriving at a known location, wherein theoutputting includes outputting the second suggestion, and wherein thesecond suggestion relates to the arrival at the known location.
 6. Thecomputer-implemented method of claim 1, wherein the contextualinformation includes previous electronic messages associated with theuser.
 7. The computer-implemented method of claim 6, wherein thecontextual information includes a date/time stamp for a particularprevious electronic message comprising a question to the user.
 8. Thecomputer-implemented method of claim 1, wherein the contextualinformation includes calendar information for the user.
 9. Thecomputer-implemented method of claim 8, wherein the calendar informationincludes at least one of (i) a type of an activity the user is currentlyengaged in and (ii) at least one of a start time and an end time of theactivity that the user is currently engaged in.
 10. Thecomputer-implemented method of claim 1, wherein (i) the first suggestionis a word and the second suggestion is a phrase or a sentence or (ii)the first suggestion is the word or the phrase and the second suggestionis the sentence.
 11. The computer-implemented method of claim 1, whereinthe second suggestion is obtained in response to the user inputting aprefix of the electronic message.
 12. The computer-implemented method ofclaim 1, wherein the computing device is a client computing deviceassociated with the user.
 13. The computer-implemented method of claim1, wherein the computing device is a server computing device that isdistinct from a client computing device associated with the user.
 14. Acomputing device, comprising: a non-transitory computer-readable mediumhaving a set of instructions stored thereon; and one or more processorsconfigured to execute the set of instructions, which causes the one ormore processors to perform operations comprising: detecting aninitiation of composing an electronic message by a user; obtainingcontextual information for the electronic message from a source externalto a text of the electronic message; obtaining a first suggestion forthe text of the electronic message based on the contextual information;detecting an operating condition indicative of a user activity duringwhich the user is likely to experience difficulty in typing; in responseto detecting the operating condition, obtaining a second suggestion forthe electronic message based on the contextual information, the secondsuggestion being more detailed than the first suggestion; and outputtingone of the first and second suggestions depending on one or more otherconditions.
 15. The computing device of claim 14, wherein the detectingof the operating condition is based on a measured gravitational force.16. The computing device of claim 15, wherein the user activity iswalking or running, and wherein the measured gravitational forceindicates that the user is walking or running.
 17. The computing deviceof claim 15, wherein the user activity is waiting in a line, and whereinthe measured gravitational force indicates that the user is waiting in aline.
 18. The computing device of claim 14, wherein the one or moreother conditions include the user arriving at a known location, whereinthe outputting includes outputting the second suggestion, and whereinthe second suggestion relates to the arrival at the known location. 19.The computing device of claim 14, wherein the contextual informationincludes previous electronic messages associated with the user.
 20. Thecomputing device of claim 19, wherein the contextual informationincludes a date/time stamp for a particular previous electronic messagecomprising a question to the user.
 21. The computing device of claim 14,wherein the contextual information includes calendar information for theuser.
 22. The computing device of claim 21, wherein the calendarinformation includes at least one of (i) a type of an activity the useris currently engaged in and (ii) at least one of a start time and an endtime of the activity that the user is currently engaged in.
 23. Thecomputing device of claim 14, wherein (i) the first suggestion is a wordand the second suggestion is a phrase or a sentence or (ii) the firstsuggestion is the word or the phrase and the second suggestion is thesentence.
 24. The computing device of claim 14, wherein the secondsuggestion is obtained in response to the user inputting a prefix of theelectronic message.
 25. The computing device of claim 14, wherein thecomputing device is a client computing device associated with the user.26. The computing device of claim 14, wherein the computing device is aserver computing device that is distinct from a client computing deviceassociated with the user.